<script>
{literal}
function setupCalendars(){Calendar.setup({dateField: 'popupDateField_{/literal}{$field_name}{literal}', triggerElement: 'popupDateField_{/literal}{$field_name}{literal}'})}
Event.observe(window, 'load', setupCalendars, false);
{/literal}
</script>
<input type="text" name="{$field_name}" class="text" id="popupDateField_{$field_name}" class="dateField" value="{$value|date_format:"d-m-Y"}" />